<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml"
    xmlns:ui="http://java.sun.com/jsf/facelets"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:rich="http://richfaces.org/rich"
    xmlns:a4j="http://richfaces.org/a4j">           


<ui:composition template="/resources/jsf/component/include/default.xhtml">
    
    <ui:define name="head">
        <ui:include src="/resources/jsf/component/composition/system/css/default.xhtml" />
    </ui:define>
    
    <ui:define name="left-content">
    </ui:define>

    <ui:define name="content">
    
        <h:form id="form_login">
            <h:panelGrid columns="3">

                <h:outputLabel for="email" value="E-mail:" />
                <h:inputText id="email" value="#{userc.userb.user.email}">
                    <f:ajax event="blur" render="m_email" />
                </h:inputText>
                <rich:message id="m_email" for="email" ajaxRendered="false" />

                <h:outputLabel for="password" value="Senha" />
                <h:inputSecret id="password" value="#{userc.userb.user.password}">
                    <f:ajax event="blur" render="m_password" />
                </h:inputSecret>
                <rich:message id="m_password" for="password" />

                <h:commandButton value="Entrar" action="#{userc.login}">
                    <f:ajax execute="@form" render="@form" />
                </h:commandButton>
                
                <a4j:status>
                    <f:facet name="start">
                        <h:graphicImage name="loader.gif" library="image" />
                    </f:facet>
                </a4j:status>
                <h:outputText />

                <h:link value="Esqueceu sua senha ?" outcome="/system/user/password/forgot-password" />
                
            </h:panelGrid>
            <ui:include src="/resources/jsf/component/composition/system/popup.xhtml" />
        </h:form>
    </ui:define> 
        
    <ui:define name="right-content" />

</ui:composition>
</html>